<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<link rel="stylesheet" href="style.css" type="text/css">
<meta content="text/html; charset=iso-8859-1" http-equiv="Content-Type">
<link rel="Start" href="index.html">
<link rel="previous" href="Lwt_pool.html">
<link rel="next" href="Lwt_util.html">
<link rel="Up" href="index.html">
<link title="Index of types" rel=Appendix href="index_types.html">
<link title="Index of exceptions" rel=Appendix href="index_exceptions.html">
<link title="Index of values" rel=Appendix href="index_values.html">
<link title="Index of class methods" rel=Appendix href="index_methods.html">
<link title="Index of class types" rel=Appendix href="index_class_types.html">
<link title="Index of modules" rel=Appendix href="index_modules.html">
<link title="Index of module types" rel=Appendix href="index_module_types.html">
<link title="Dom" rel="Chapter" href="Dom.html">
<link title="Gears" rel="Chapter" href="Gears.html">
<link title="Javascript" rel="Chapter" href="Javascript.html">
<link title="Jslib_ast" rel="Chapter" href="Jslib_ast.html">
<link title="Jslib_lexer" rel="Chapter" href="Jslib_lexer.html">
<link title="Jslib_parse" rel="Chapter" href="Jslib_parse.html">
<link title="Jslib_pp" rel="Chapter" href="Jslib_pp.html">
<link title="Lwt" rel="Chapter" href="Lwt.html">
<link title="Lwt_dom" rel="Chapter" href="Lwt_dom.html">
<link title="Lwt_mutex" rel="Chapter" href="Lwt_mutex.html">
<link title="Lwt_pool" rel="Chapter" href="Lwt_pool.html">
<link title="Lwt_timeout" rel="Chapter" href="Lwt_timeout.html">
<link title="Lwt_util" rel="Chapter" href="Lwt_util.html">
<link title="Mozilla" rel="Chapter" href="Mozilla.html">
<link title="Ocamljs" rel="Chapter" href="Ocamljs.html"><title>Lwt_timeout</title>
</head>
<body>
<div class="navbar"><a href="Lwt_pool.html">Previous</a>
&nbsp;<a href="index.html">Up</a>
&nbsp;<a href="Lwt_util.html">Next</a>
</div>
<center><h1>Module <a href="type_Lwt_timeout.html">Lwt_timeout</a></h1></center>
<br>
<pre><span class="keyword">module</span> Lwt_timeout: <code class="code">sig</code> <a href="Lwt_timeout.html">..</a> <code class="code">end</code></pre>set the default handler for exception occurring after a timeout.
    The function lauched after a timeout should not raise any exception.
    That's why the default handler will exit the program.<br>
<hr width="100%">
<pre><span class="keyword">type</span> <a name="TYPEt"></a><code class="type"></code>t </pre>

<pre><span class="keyword">val</span> <a name="VALset_exn_handler"></a>set_exn_handler : <code class="type">(exn -> unit) -> unit</code></pre><div class="info">
set the default handler for exception occurring after a timeout.
    The function lauched after a timeout should not raise any exception.
    That's why the default handler will exit the program.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALcreate"></a>create : <code class="type">int -> (unit -> unit) -> <a href="Lwt_timeout.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">create n f</code> defines a new timeout with <code class="code">n</code> seconds duration. <code class="code">f</code> is
    the function to be called after the timeout.
    That function must not raise any exception.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALstart"></a>start : <code class="type"><a href="Lwt_timeout.html#TYPEt">t</a> -> unit</code></pre><div class="info">
starts a timeout.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALstop"></a>stop : <code class="type"><a href="Lwt_timeout.html#TYPEt">t</a> -> unit</code></pre><div class="info">
stops a timeout.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALchange"></a>change : <code class="type"><a href="Lwt_timeout.html#TYPEt">t</a> -> int -> unit</code></pre><div class="info">
changes the duration of a timeout.<br>
</div>
</body></html>